package io.renren.modules.dangan.controller;

import java.util.Arrays;
import java.util.Map;

import io.renren.common.validator.ValidatorUtils;
import io.renren.commons.dynamic.datasource.annotation.DataSource;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import io.renren.modules.dangan.entity.TCqzswktEntity;
import io.renren.modules.dangan.service.TCqzswktService;
import io.renren.common.utils.PageUtils;
import io.renren.common.utils.R;



/**
 * ${comments}
 *
 * @author Mark
 * @email sunlightcs@gmail.com
 * @date 2019-11-15 13:54:45
 */
@RestController
@RequestMapping("/tcqzswkt")
@DataSource("dlmis")
public class TCqzswktController {
    @Autowired
    private TCqzswktService tCqzswktService;

    /**
     * 列表
     */
    @RequestMapping("/list")
    public R list(@RequestParam Map<String, Object> params){
        PageUtils page = tCqzswktService.queryPage(params);

        return R.ok().put("page", page);
    }


    /**
     * 信息
     */
    @RequestMapping("/info/{bsm}")
    public R info(@PathVariable("bsm") Integer bsm){
        TCqzswktEntity tCqzswkt = tCqzswktService.getById(bsm);

        return R.ok().put("tCqzswkt", tCqzswkt);
    }


}
